package com.hqhsc.module.manage.activityuser.domain;

import org.springframework.jdbc.core.RowMapper;

import java.sql.ResultSet;
import java.sql.SQLException;

public class ActivityUserRowMapper implements RowMapper<ActivityUser>{
	public ActivityUser mapRow(ResultSet rs, int arg1) throws SQLException {
        ActivityUser activityUser=new ActivityUser();

        activityUser.setId(rs.getInt("id"));
        activityUser.setName(rs.getString("name"));
        activityUser.setSex(rs.getString("sex"));
        activityUser.setDn(rs.getString("dn"));

        activityUser.setId_card(rs.getString("id_card"));
        activityUser.setAddress(rs.getString("address"));
        activityUser.setWedding_date(rs.getString("wedding_date"));
        activityUser.setBudget(rs.getString("budget"));
        activityUser.setMarry_require(rs.getString("marry_require"));
        activityUser.setOther_require(rs.getString("other_require"));

        activityUser.setActivity_id(rs.getLong("activity_id"));
        activityUser.setActivity_name(rs.getString("activity_name"));
        activityUser.setChannel_id(rs.getLong("channel_id"));
        activityUser.setChannel_name(rs.getString("channel_name"));

        activityUser.setIs_buy(rs.getString("is_buy"));
        activityUser.setNobuy_reason(rs.getString("nobuy_reason"));
        activityUser.setBuy_googds(rs.getString("buy_googds"));
        activityUser.setPay_amount(rs.getDouble("pay_amount"));
        activityUser.setIs_discount(rs.getString("is_discount"));

        activityUser.setCreate_at(rs.getString("create_at"));

        activityUser.setIs_sign(rs.getInt("is_sign"));

		return activityUser;
	}
}
